package com.chorye.function.pdf.read.controller;

import com.chorye.function.pdf.read.service.PdfReadService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.multipart.MultipartFile;

/**
 * @Company: 北京XXXX有限公司
 * @Author JiangYy
 * @Title: PDFReadController
 * @Description: pdf导入控制层
 * @Date 2019/7/22 14:50
 */
@Controller
@RequestMapping("/pdf/read/")
public class PdfReadController {

    /**
     * pdf导入服务层
     */
    @Autowired
    private PdfReadService pdfReadService;

    /**
     * 导入pdf文件
     *
     * @param file 文件
     */
    @RequestMapping("/import")
    public void importPDF(MultipartFile file) {
        pdfReadService.importPDF(file);
    }
}
